package com.kmzx.one.project.service;

import com.kmzx.one.project.others.dto.CartDiscountInfo;
import com.kmzx.one.project.others.dto.ProdOutInfo;
import com.kmzx.one.project.others.dto.UserCartInfo;
import com.kmzx.one.project.others.dto.UserCartLimitInfo;

import java.util.List;

// service find 前缀
// mapper select前缀
public interface UserCartService extends BaseService {

    // 购物车列表
    List<UserCartInfo> findMyShoppingCart() throws Exception;

    // 删除购物车商品
    Integer doDelCart(String userId, String[] cartIdArr) throws Exception;

    // 添加到购物车
    Integer doAddCart(String userId, String productId, String skuId, Integer count) throws Exception;

    // 添加到购物车
    Integer doAddCart2(String userId, String productId, String skuId, String tradeNum, Integer count) throws Exception;

    // 增加减商品
    Integer doAddOrSubtractGoods(String cartId, Integer count) throws Exception;

    // 发现购物车打折信息
    CartDiscountInfo findDiscountInfo(String userId) throws Exception;

    Integer findSkuIdNum(String skuId) throws Exception;

    List<ProdOutInfo> getRecommendProdList(String userId, Integer pageNum, Integer pageSize);

    boolean checkIdsIsOk(String[] ids, String userId);

    int totalCartNum(String userId);

    //  贸易仓库最多限制数
    List<UserCartLimitInfo> findUserCartLimitInfo();
}
